home *** CD-ROM | disk | FTP | other *** search
- %BEGIN Bitmaps
- /lengthByte 1 string def
- /runByte 1 string def
-
- /unpackbytes
- {
- /thelength
- currentfile lengthByte readhexstring pop
- 0 get
- def
- thelength 128 lt
- {
- /dataString thelength 1 add string def
- currentfile dataString readhexstring pop
- }
- {
- /runlength 257 thelength sub def
- /runString runlength string def
- currentfile runByte readhexstring pop pop
-
- 0 1 runlength 1 sub
- { runString exch runByte putinterval }
- for
- runString
- }
- ifelse
- }
- def
- /bitmap
- {
- gsave
- {
- initclip
- regionBounds
- clip
- /numShapes exch def
- numShapes 0 gt
- {
- numShapes
- regionPath
- clip
- }
- if
- }
- if
- /isPacked exch def
- /sourceHeight exch def
- /sourceWidth exch def
- /destHeight exch def
- /destWidth exch def
- /boty exch def
- /botx exch def
- /mode exch def
- /bitDepth exch def % unused
- /colordata exch def % "
- /numcolors exch def % "
- /scanString sourceWidth 8 div ceiling cvi string def
- botx boty destHeight add translate
- destWidth destHeight scale
- 0 setgray
- PSlevel 1 eq
- {
- mode /srcOr eq
- mode /notSrcOr eq
- or
- {
- sourceWidth sourceHeight mode /notSrcOr eq
- [sourceWidth 0 0 sourceHeight 0 sourceHeight]
- isPacked true eq
- { {unpackbytes} }
- { {currentfile scanString readhexstring pop} }
- ifelse
- imagemask
- }
- {
- sourceWidth sourceHeight 1
- [sourceWidth 0 0 sourceHeight 0 sourceHeight]
- isPacked true eq
- { {unpackbytes} }
- { {currentfile scanString readhexstring pop} }
- ifelse
- image
- }
- ifelse
- isPacked false eq
- { 2 { currentfile read pop pop } repeat }
- { 4 { currentfile read pop pop } repeat }
- ifelse
- }
- {
- /DeviceGray setcolorspace
- /imageParams 7 dict def
- imageParams begin
- /ImageType 1 def
- /Width sourceWidth def
- /Height sourceHeight def
- /BitsPerComponent 1 def
- /Decode mode /notSrcOr eq
- { [ 1 0 ] } { [ 0 1 ] } ifelse def
- /ImageMatrix [sourceWidth 0 0 sourceHeight
- 0 sourceHeight] def
- /DataSource isPacked true eq
- { currentfile /ASCIIHexDecode filter
- /RunLengthDecode filter}
- { currentfile /ASCIIHexDecode filter}
- ifelse
- def
- end
- mode /srcOr eq
- mode /notSrcOr eq
- or
- { imageParams imagemask }
- { imageParams image }
- ifelse
- }
- ifelse
- grestore
- }
- def
- /colorbitmap
- {
- gsave
- {
- initclip
- regionBounds
- clip
- /numShapes exch def
- numShapes 0 gt
- {
- numShapes
- regionPath
- clip
- }
- if
- }
- if
- /isPacked exch def
- /sourceHeight exch def
- /sourceWidth exch def
- /destHeight exch def
- /destWidth exch def
- /boty exch def
- /botx exch def
- /mode exch def
- /sampleDepth exch def
- /colordata exch def
- /numcolors exch def
- botx boty destHeight add translate
- destWidth destHeight scale
- PSlevel 1 eq
- {
- /scanString sourceWidth sampleDepth mul 8 div
- ceiling cvi string def
- sourceWidth sourceHeight sampleDepth
- [sourceWidth 0 0 sourceHeight 0 sourceHeight]
- isPacked true eq
- { {unpackbytes} }
- { {currentfile scanString readhexstring pop} }
- ifelse
- image
- isPacked false eq
- { 2 { currentfile read pop pop } repeat }
- { 4 { currentfile read pop pop } repeat }
- ifelse
- }
- {
- [ /Indexed /DeviceRGB numcolors colordata] setcolorspace
- /imageParams 7 dict def
- imageParams begin
- /ImageType 1 def
- /Width sourceWidth def
- /Height sourceHeight def
- /BitsPerComponent sampleDepth def
- /Decode [ 0 2 sampleDepth exp 1 sub ] def
- /ImageMatrix [sourceWidth 0 0 sourceHeight 0
- sourceHeight] def
- /DataSource isPacked true eq
- { currentfile /ASCIIHexDecode filter
- /RunLengthDecode filter}
- { currentfile /ASCIIHexDecode filter}
- ifelse
- def
- end
- imageParams image
- }
- ifelse
- grestore
- }
- def
- /24bitBitmap
- {
- gsave
- {
- initclip
- regionBounds
- clip
- /numShapes exch def
- numShapes 0 gt
- {
- numShapes
- regionPath
- clip
- }
- if
- }
- if
- /isPacked exch def
- /sourceHeight exch def
- /sourceWidth exch def
- /destHeight exch def
- /destWidth exch def
- /boty exch def
- /botx exch def
- /mode exch def
- botx boty destHeight add translate
- destWidth destHeight scale
- /scanString sourceWidth 3 mul string def
- sourceWidth sourceHeight 8
- [sourceWidth 0 0 sourceHeight 0 sourceHeight]
- isPacked true eq
- { {unpackbytes} }
- { {currentfile scanString readhexstring pop} }
- ifelse
- false 3
- colorimage
- grestore
- }
- def
- %END Bitmaps
-